/*******************************************************************************
 * Copyright (c) 2010 Mikhail Garber.
 * All rights reserved. This program and the accompanying materials
 * are made available under the terms of the GNU Lesser Public License (LGPL)
 * which accompanies this distribution
 * 
 * Contributors:
 *     Mikhail Garber - initial API and implementation
 ******************************************************************************/
package plumber.component;

import plumber.context.FlowContext;

/**
 * Interface for a Component Manager
 * @author mgarber
 *
 */
public interface ComponentManager {

	/**
	 * find a component given its name and desired method name
	 * @param componentName
	 * @param methodName
	 * @return object (the component itself)
	 */
	public Object find(String componentName, String methodName);
	
	/**
	 * find an execute a component
	 * @param componentName
	 * @param methodName
	 * @param context - item context from the workflow
	 * @return result of execution
	 */
	public Object execute(String componentName, String methodName, FlowContext context);
	
}
